#!/bin/sh

name=$1
libname=$2
staticlibdir=$3
otherstaticlibdir=$4

if [ -z $name ]; then
  echo "specify name";
  exit;
fi

rm -rf ./$name

mkdir -p $name/lib
mkdir -p $name/include/
 
cp LICENSE.GPL $name/
cp $libname $name/lib
cp $staticlibdir/libdingo.a $name/lib

cp ../render2d/$otherstaticlibdir/librender2d.a $name/lib
cp ../layout/$otherstaticlibdir/liblayout.a $name/lib
cp ../reaction/$otherstaticlibdir/libreaction.a $name/lib
cp ../molecule/$otherstaticlibdir/libmolecule.a $name/lib
cp ../graph/$otherstaticlibdir/libgraph.a $name/lib
cp c/dingo_c.h $name/include

zip -r -9 $name.zip $name

